package bo.zhao.action.factory_method.factory;

import bo.zhao.action.simple_factory.product.ISender;
import bo.zhao.action.simple_factory.product.MailSender;

public class MailSenderFactory implements ISenderFactory {

	@Override
	public ISender produce() {
		//创建对象
		ISender sender = new MailSender();
		//配置对象
		sender.setDelay(9);
		//调用初始化方法
		sender.init();
		sender.prepare();
		//
		return sender;
	}

}
